package com.moli.iov.base.enums;

/**
 * 审核结果
 *
 * @author wanghualin
 * @date 2020 -02-24 15:22:04
 */
public enum  AuditResultsEnum {
    NO  (0, "不同意安装"),
    YES(1, "同意安装");

    private int code;
    private String name;

    private AuditResultsEnum(int code, String name) {
        this.code = code;
        this.name = name;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public static String getCodeName(int code) {
        for (AuditResultsEnum e : AuditResultsEnum.values()) {
            if (e.code == code) {
                return e.name;
            }
        }
        return null;
    }
}
